<template>
  <div class="app-container">
    <div style="width: 600px; margin: 0 auto">
      <tbody>
      <tr style="height:28.35pt">
        <td
          style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; padding-left:5.03pt; padding-right:5.03pt; vertical-align:middle">
          <p style="margin:0pt; orphans:0; text-align:justify; widows:0"><span
            style="font-family:宋体; font-size:10.5pt; font-weight:bold">第一部分：废物产生单位填写</span></p></td>
        <td rowspan="7"
            style="border-bottom-color:#ffffff; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#ffffff; border-right-style:solid; border-right-width:0.75pt; border-top-color:#ffffff; border-top-style:solid; border-top-width:0.75pt; padding-left:5.03pt; padding-right:5.03pt; vertical-align:middle">
          <!--        <p style="margin:5pt 0pt; text-align:center"><span style="font-family:宋体; font-size:10.5pt">第一联</span></p>-->
          <!--        <p style="margin:0pt; orphans:0; text-align:justify; widows:0"><span style="font-family:宋体; font-size:10.5pt">产生单位</span>-->
          </p></td>
      </tr>
      <tr>
        <td
          style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; padding-left:5.03pt; padding-right:5.03pt; vertical-align:top">
          <p style="line-height:12pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:9pt">&nbsp;</span></p>
          <p style="line-height:12pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">产生单位</span><span
            style="font-family:宋体; font-size:10.5pt"> <span  class="text">{{person.epName}}</span> 单位盖章 </span>
            <span style="font-family:宋体; font-size:10.5pt">&nbsp;&nbsp; </span><span style="font-family:宋体; font-size:10.5pt">电话 <span class="smell">{{person.epPhone}}</span></span>
          </p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">通讯地址</span><span
            style="font-family:宋体; font-size:10.5pt"><span style="" class="text">{{value.wxfwzyYcEp}}</span> 邮编<span class="smell"></span></span>
          </p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">运输单位</span><span
            style="font-family:宋体; "><span style="" class="text">{{value.wxfwzyJcEp}}</span> 电话 <span class="smell">{{value.wxfwzyYcPhone}}</span></span>
          </p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">通讯地址</span><span
            style="font-family:宋体; font-size:10.5pt"><span style="" class="text"></span> 邮编<span class="smell"></span></span>
          </p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">接受单位</span><span
            style="font-family:宋体; font-size:10.5pt"><span style="" class="text">{{value.wxfwzyJcPerson}}</span> 电话<span class="smell">{{value.wxfwzyJcPhone}}</span></span>
          </p>
          <p style="margin:0pt; orphans:0; text-align:justify; widows:0"><span style="font-family:宋体; font-size:10.5pt">通讯地址</span><span
            style="font-family:宋体; font-size:10.5pt"> </span><span
            style="font-family:'Times New Roman'; font-size:10.5pt"><span style="" class="text"></span> 邮编 </span>
            <span
            style="font-family:宋体; font-size:10.5pt"></span><span
            style="font-family:'Times New Roman'; font-size:10.5pt">________________</span></p></td>
      </tr>
      <tr>
        <td
          style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; padding-left:5.03pt; padding-right:5.03pt; vertical-align:top">
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">&nbsp;</span></p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">废物名称</span><span
            style="font-family:宋体; font-size:10.5pt"> __________________类别编号__________________ 数量________________</span>
          </p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">废物特性：</span><span
            style="font-family:宋体; font-size:10.5pt">__________________ 形态 ________________ 包装方式______________</span></p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">外运目的：中转贮存</span><span
            style="font-family:宋体; font-size:10.5pt"> 利用 处理 处置 </span></p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">主要危险成分</span><span
            style="font-family:宋体; font-size:10.5pt"> _________________________禁忌与应急措施 _____________________</span></p>
          <p style="margin:0pt; orphans:0; text-align:justify; widows:0"><span style="font-family:宋体; font-size:10.5pt">发运人</span><span
            style="font-family:宋体; font-size:10.5pt"> </span><span
            style="font-family:'Times New Roman'; font-size:10.5pt">_____________ </span><span
            style="font-family:宋体; font-size:10.5pt">运达地 </span><span
            style="font-family:'Times New Roman'; font-size:10.5pt">______________ </span><span
            style="font-family:宋体; font-size:10.5pt">转移时间</span><span
            style="font-family:'Times New Roman'; font-size:10.5pt">________</span><span
            style="font-family:宋体; font-size:10.5pt">年</span><span
            style="font-family:'Times New Roman'; font-size:10.5pt">____ </span><span
            style="font-family:宋体; font-size:10.5pt">月</span><span
            style="font-family:'Times New Roman'; font-size:10.5pt">____</span><span
            style="font-family:宋体; font-size:10.5pt">日</span></p></td>
      </tr>
      <tr style="height:28.35pt">
        <td
          style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; padding-left:5.03pt; padding-right:5.03pt; vertical-align:middle">
          <p style="margin:0pt; orphans:0; text-align:justify; widows:0"><span
            style="font-family:宋体; font-size:10.5pt; font-weight:bold">第二部分：废物运输单位填写</span></p></td>
      </tr>
      <tr>
        <td
          style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; padding-left:5.03pt; padding-right:5.03pt; vertical-align:top">
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">运输者须知：你必须核对以上栏目事项，当与实际情况不符时，有权拒绝接受。</span>
          </p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">第一承运人</span><span
            style="font-family:宋体; font-size:10.5pt"> ________________________________运输日期________年____月____日</span></p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">车（船）型：</span><span
            style="font-family:宋体; font-size:10.5pt">________________ 牌号________________道路运输证号_____________</span></p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">运输起点</span><span
            style="font-family:宋体; font-size:10.5pt">__________经由地___________运输终点___________ 运输人签字_________</span></p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">第二承运人</span><span
            style="font-family:宋体; font-size:10.5pt"> _______________________运输日期______年__月__日</span></p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">车（船）型：</span><span
            style="font-family:宋体; font-size:10.5pt">________________牌号_________________道路运输证号_____________</span></p>
          <p style="margin:0pt; orphans:0; text-align:justify; widows:0"><span style="font-family:宋体; font-size:10.5pt">运输起点</span><span
            style="font-family:'Times New Roman'; font-size:10.5pt">________</span><span
            style="font-family:宋体; font-size:10.5pt">经由地</span><span
            style="font-family:'Times New Roman'; font-size:10.5pt">_________</span><span
            style="font-family:宋体; font-size:10.5pt">运输终点</span><span
            style="font-family:'Times New Roman'; font-size:10.5pt">___________ </span><span
            style="font-family:宋体; font-size:10.5pt">运输人签字</span><span
            style="font-family:'Times New Roman'; font-size:10.5pt">_____________</span></p></td>
      </tr>
      <tr style="height:28.35pt">
        <td
          style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; padding-left:5.03pt; padding-right:5.03pt; vertical-align:middle">
          <p style="margin:0pt; orphans:0; text-align:justify; widows:0"><span
            style="font-family:宋体; font-size:10.5pt; font-weight:bold">第三部分：废物接受单位填写</span></p></td>
      </tr>
      <tr>
        <td
          style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; padding-left:5.03pt; padding-right:5.03pt; vertical-align:top">
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">接受者须知：你必须核实以上栏目内容，当与实际情况不符时，有权拒绝接受。</span>
          </p>
          <p style="line-height:13pt; margin:5pt 0pt"><span style="font-family:宋体; font-size:10.5pt">经营许可证号</span><span
            style="font-family:宋体; font-size:10.5pt">__________________接收人 ____________ 接收日期 ______________</span></p>
          <p style="line-height:13pt; margin:5pt 0pt"><span
            style="font-family:宋体; font-size:10.5pt">废物处置方式：利用□ </span><span
            style="font-family:宋体; font-size:10.5pt">贮存</span><span style="font-family:宋体; font-size:10.5pt">□</span><span
            style="font-family:宋体; font-size:10.5pt"> 焚烧</span><span
            style="font-family:宋体; font-size:10.5pt">□</span><span
            style="font-family:宋体; font-size:10.5pt"> 安全填埋</span><span
            style="font-family:宋体; font-size:10.5pt">□</span><span
            style="font-family:宋体; font-size:10.5pt"> 其他</span><span style="font-family:宋体; font-size:10.5pt">□</span></p>
          <p style="margin:0pt; orphans:0; text-align:justify; widows:0"><span
            style="font-family:宋体; font-size:10.5pt; font-weight:normal">单位负责人签字</span><span
            style="font-family:'Times New Roman'; font-size:10.5pt; font-weight:normal">__________________________ </span><span
            style="font-family:宋体; font-size:10.5pt; font-weight:normal">单位盖章 </span><span
            style="font-family:宋体; font-size:10.5pt; font-weight:normal">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span><span
            style="font-family:宋体; font-size:10.5pt; font-weight:normal">日期</span><span
            style="font-family:'Times New Roman'; font-size:10.5pt; font-weight:normal">_____________</span></p></td>
      </tr>
      </tbody>
    </div>




  </div>
</template>

<script>
import {
  addCftzInfo,
  delCftzInfo,
  exportCftzInfo,
  getCftzInfo,
  listCftzInfo,
  updateCftzInfo
} from "@/api/solidProdution/cftzInfo";
import {InfoItem} from "@/api/enterprise/info";
import {listProcess} from "@/api/enterprise/process";


export default {
  name: "CftzInfo",
  data() {
    return {
      value:"",
      // 遮罩层
      loading: true,
      // 导出遮罩层
      exportLoading: false,
      // 选中数组
      ids: [],
      // 非单个禁用
      single: true,
      // 非多个禁用
      multiple: true,
      // 显示搜索条件
      showSearch: true,
      // 总条数
      total: 0,
      // 产废台账表格数据
      cftzInfoList: [],
      // 弹出层标题
      title: "",
      // 是否显示弹出层
      open: false,
      // 查询参数
      queryParams: {
        pageNum: 1,
        pageSize: 10,
        cftzEpName: null,
        cftzCode: null,
        cftzVideo: null,
        cftzWxfwName: null,
        cftzType: null,
        cftzTx: null,
        cftzNum: null,
        cftzLx: null,
        cftzTime: null,
        other: null,
        otherOne: null
      },
      person:{

      },
      // 表单参数
      form: {},
      // 表单校验
      rules: {
        cftzEpName: [
          {required: true, message: "名称不能为空", trigger: "blur"}
        ]
      },
      typeOptions: [],
      typeOptions_tx: [],
      typeOptions_lx: [],
    };
  },
  created() {
    this.getListI()
    setTimeout(function(){
      window.print()
    },1000);
    // this.getDicts("wxfwxt").then(response => {
    //   this.typeOptions = response.data;
    // });
    // this.getDicts("wxtx").then(response => {
    //   this.typeOptions_tx = response.data;
    // });
    // this.getDicts("lx").then(response => {
    //   this.typeOptions_lx = response.data;
    // });
    // this.getList();
  },
  mounted() {
    this.value=JSON.parse(this.$route.query.content)[0]
     console.log( this.value)
    },
  methods: {
    print(){

    },
    getListI() {
      this.loading = true;
      const username = this.$store.state.user.name;
      InfoItem(username).then(res => {
        if (res.hasOwnProperty("data")) {
          this.person = res.data;
           console.log( 2222,this.person)

        }
      })
    },
    typeFormat(row, column) {
      return this.selectDictLabel(this.typeOptions, row.cftzType);
    },
    typeFormat_tx(row, column) {
      return this.selectDictLabel(this.typeOptions_tx, row.cftzTx);
    },
    /** 查询产废台账列表 */
    getList() {
      this.loading = true;
      listCftzInfo(this.queryParams).then(response => {
        this.cftzInfoList = response.rows;
        this.total = response.total;
        this.loading = false;
      });
    },
    // 取消按钮
    cancel() {
      this.open = false;
      this.reset();
    },
    // 表单重置
    reset() {
      this.form = {
        cftzId: null,
        cftzEpName: null,
        cftzCode: null,
        cftzVideo: null,
        cftzWxfwName: null,
        cftzType: null,
        cftzTx: null,
        cftzNum: null,
        cftzLx: null,
        cftzTime: null,
        delFlag: null,
        createBy: null,
        createTime: null,
        updateBy: null,
        updateTime: null,
        remark: null,
        other: null,
        otherOne: null
      };
      this.resetForm("form");
    },
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNum = 1;
      this.getList();
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.resetForm("queryForm");
      this.handleQuery();
    },
    // 多选框选中数据
    handleSelectionChange(selection) {
      this.ids = selection.map(item => item.cftzId)
      this.single = selection.length !== 1
      this.multiple = !selection.length
    },
    /** 新增按钮操作 */
    handleAdd() {
      this.reset();
      this.open = true;
      this.title = "添加产废台账";
    },
    /** 修改按钮操作 */
    handleUpdate(row) {
      this.reset();
      const cftzId = row.cftzId || this.ids
      getCftzInfo(cftzId).then(response => {
        this.form = response.data;
        this.open = true;
        this.title = "修改产废台账";
      });
    },
    /** 提交按钮 */
    submitForm() {
      this.$refs["form"].validate(valid => {
        if (valid) {
          if (this.form.cftzId != null) {
            updateCftzInfo(this.form).then(response => {
              this.msgSuccess("修改成功");
              this.open = false;
              this.getList();
            });
          } else {
            addCftzInfo(this.form).then(response => {
              this.msgSuccess("新增成功");
              this.open = false;
              this.getList();
            });
          }
        }
      });
    },
    /** 删除按钮操作 */
    handleDelete(row) {
      const cftzIds = row.cftzId || this.ids;
      this.$confirm('是否确认删除产废台账编号为"' + cftzIds + '"的数据项?', "警告", {
        confirmButtonText: "确定",
        cancelButtonText: "取消",
        type: "warning"
      }).then(function () {
        return delCftzInfo(cftzIds);
      }).then(() => {
        this.getList();
        this.msgSuccess("删除成功");
      }).catch(() => {
      });
    },
    /** 导出按钮操作 */
    handleExport() {
      const queryParams = this.queryParams;
      this.$confirm('是否确认导出所有产废台账数据项?', "警告", {
        confirmButtonText: "确定",
        cancelButtonText: "取消",
        type: "warning"
      }).then(() => {
        this.exportLoading = true;
        return exportCftzInfo(queryParams);
      }).then(response => {
        this.download(response.msg);
        this.exportLoading = false;
      }).catch(() => {
      });
    }
  }
};
</script>
<style scoped>
.text{


    box-sizing: border-box;
  padding-left: 5px;
  font-size: 14px;
  display: inline-block;

}

.text:first-letter{


}

.text:after {

  content: '';

  display: block;

  width: 295px;

  margin-top: -2px;

  border-bottom: 1px solid rgb(0, 0, 0);
}

.smell{


  box-sizing: border-box;
  padding-left: 5px;
  font-size: 14px;
  display: inline-block;

}

.smell:first-letter{


}

.smell:after {

  content: '';

  display: block;

  width:100px;

  margin-top: -2px;

  border-bottom: 1px solid rgb(0, 0, 0);
}

</style>
